package com.itheima.extends_demo;
// 子类只能使用父类的非私有的功能
public class Teacher extends Person {
    private String workId;

    public String getWorkId() {
        return workId;
    }

    public void setWorkId(String workId) {
        this.workId = workId;
    }

    public void teach() {
        System.out.println("老师授课...");
    }
 
}
